<?php
$loader->requireOnce('includes/RadException.class.php');
$loader->requireOnce('includes/RadQueue/RadWaitingQueue.class.php');
$loader->requireOnce('includes/RadQueue/RadInProgressQueue.class.php');
class RadQueueFactory {
    public static function createQueue($queueType) {
        switch($queueType) {
        	case ARadQueue::QUEUE_TYPE_WAITING:
        		return new RadWaitingQueue();
        	case ARadQueue::QUEUE_TYPE_INPROGRESS:
        		return new RadInProgressQueue();
        	default:
        	   throw new RadException("Radiology queue type '$queueType' is not supported", RadErrorCode::QUEUE_TYPE_NOT_SUPPORTED);
        }
    }
}
?>